package com.igeek.dao.impl;

import org.springframework.beans.factory.annotation.Value;
import org.springframework.context.annotation.ComponentScan;
import org.springframework.stereotype.Component;
import org.springframework.stereotype.Repository;

@Repository("bookDao")
public class BookDaoImpl implements BookDao {
    @Value("1")
    private int connectionNum;
    @Value("${name}")
    private String databaseNum;


//    public void setConnectionNum(int connectionNum) {
//        this.connectionNum = connectionNum;
//    }
//
//
//    public void setDatabaseNum(String databaseNum) {
//        this.databaseNum = databaseNum;
//    }

    public void save() {
        System.out.println("我真帅" + databaseNum + " " + connectionNum);
    }
    public void update() {
        System.out.println("我真帅啊");
    }
    public int select() {
        System.out.println("select is running");
        return 1;
    }
    public String findName(int id,String pwd){
        System.out.println("id:"+id);
        return "igeek";
    }
}
//public void init(){
//    System.out.println("初始化");
//}
//public  void destroy(){
//    System.out.println("销毁");
//}
//}
